<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <script th:src="@{/static/js/jquery.min.js}"></script>
    <script th:src="@{/static/js/vue.min.js}"></script>
    <script th:src="@{/static/js/axios.js}"></script>
    <script th:src="@{/static/js/head.js}"></script>

</head>

<div th:fragment="header1">
<nav class="navbar navbar-inverse navbar-fixed-top" id="nav">
    <div class="container-fluid">
        <div class="navbar-header">
            <a class="navbar-brand" href="#">高效视频资源网站</a>
        </div>
        <div id="head">
            <ul class="nav navbar-nav">
                <li><a href="getAllNews">首页</a></li>
                <li><a href="getVideoListByUser">视频教程</a></li>
                <li><a href="getSourceListByUser">资料下载</a></li>
                <li><a href="getMessageTopicList">学习论坛</a></li>
                <li><a href="toUserHome">个人中心</a></li>
<!--                <li><a href="getScoreBoardList">积分排行榜</a></li>-->
                <li><a href="toAbout">关于</a></li>
            </ul>
            <ul class="nav navbar-nav navbar-right" th:if="${session.user==null}">
                <li><a href="toLogin">登录</a></li>
                <li><a href="toRegister">注册</a></li>
            </ul>

            <ul class="nav navbar-nav navbar-right" th:if="${session.user!=null}">
                <li><a href="#" th:text="'欢迎你，'+${session.user.getUsername() }"></a></li>

                <li><a href="chat" th:text="'消息'"></a></li>
                <li><a href="logout">退出</a></li>
            </ul>

        </div>
    </div>
</nav>
</div>

</html>

